<!DOCTYPE html>
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
    <meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
    <title>运动康复方案表</title>
    <link rel="stylesheet" href="../../res/layui/css/layui.css" media="all">
    <link href="../../res/css/bootstrap.min.css" rel="stylesheet">
    <script src="../../res/js/jquery-3.1.1.min.js" charset="utf-8"></script>
    <script type="text/javascript" src="../../res/js/login_common.js"></script>
    <script src="../../res/layui/layui.js"></script>
    <style>
        body{margin: 10px;}
        .demo-carousel{height: 200px; line-height: 200px; text-align: center;}
        #detail{
            position: absolute;
            top:4px;
            left:15px;
        }
        #feedback{
            position: absolute;
            top:4px;
            left:60px;
        }
        #audit{
            position: absolute;
            top:4px;
            left:110px;
        }
        #dian{
            position: absolute;
            top:4px;
        }

        #dian2{
            position: absolute;
            top:4px;
        }

        #dian3{
            position: absolute;
            top:4px;
        }

        #dian4{
            position: absolute;
            top:4px;
        }


        #consult{
            position: absolute;
            top:4px;
            left:210px;
        }
        #edit{
            position: absolute;
            top:4px;
            left:280px;
        }
        #del{
            position: absolute;
            top:4px;
            left:335px;
        }


    </style>
</head>

<script type="text/html" id="thead">
    <div class="layui-inline">
        <input type="text" name="coachName" class="layui-input" style="height: 33px;width:130px" id="coachName" placeholder="请输入教练员名称" class="form-control" >
    </div>
    <div class="layui-inline">
        <input type="text" name="schemeName" class="layui-input" style="height: 33px;width:120px" id="schemeName" placeholder="请输入方案名称" class="form-control" >
    </div>
    <div class="layui-inline">
        <input type="text" name="begin" class="layui-input" id="begin" style="height: 33px;width:120px" placeholder="请选择开始时间" width="400px">
    </div>
    <div class="layui-inline">
        <input type="text" name="end" class="layui-input" id="end" style="height: 33px;width:120px" placeholder="请选择结束时间">
    </div>
    <div class="layui-inline">
        <button type="button" lay-event="select" class="layui-btn layui-btn-sm">搜索</button>
    </div>
    {{# if(hasPrivilege("add")){ }}
    <div class="layui-inline">
        <button type="button" lay-event="add" id="add" class="layui-btn layui-btn-sm">新增</button>
    </div>
    {{# } }}
    <div class="layui-inline">
        <button type="button" lay-event="empty" class="layui-btn layui-btn-sm">清空</button>
    </div>
    {{# if(hasPrivilege("dels")){ }}
    <div class="layui-inline">
        <button type="button" id="deletes" lay-event="deletes" class="layui-btn layui-btn-sm">批量删除</button>
    </div>
    {{# } }}
    {{# if(hasPrivilege("oneself")){ }}
    <div class="layui-inline">
        <button type="button" id="oneself" lay-event="oneself" class="layui-btn layui-btn-sm">只看自己</button>
    </div>
    {{# } }}
    {{# if(hasPrivilege("checkall")){ }}
    <div class="layui-inline">
        <button type="button" id="all" lay-event="all" class="layui-btn layui-btn-sm">查看全部</button>
    </div>
    {{# } }}
</script>
<body>
<input type="text" name="expertId" class="layui-input" id="expertId" placeholder="专家id" hidden>
<input type="text" name="companyName" id="companyName" hidden>
<input type="text" name="coachId" class="layui-input" id="coachId" placeholder="登录人id" hidden>
<input type="text" name="schemeId" class="layui-input" id="schemeId" placeholder="方案id" hidden>
<input type="text" name="coachNames" id="coachNames" placeholder="请输入教练员名称" hidden>
<input type="text" name="schemeNames" id="schemeNames" placeholder="请输入方案名称" hidden>
<input type="text" name="begins" class="layui-input" id="begins" placeholder="请选择开始时间" hidden>
<input type="text" name="ends" class="layui-input" id="ends" placeholder="请选择结束时间" hidden>
<table class="layui-hide" id="demo" lay-filter="test" lay-data></table>


<script type="text/javascript">
    $(function(){
        var url = "../../User/findSession";
        $.post(url,null,function(obj){
            if(obj.companyId == 4){ //当登录人身份是运动员时
                window.location.href = "athlete.html";//跳转到运动员界面
            }else if(obj.companyId == 2){ //当登录人身份是教练员时
                $("#coachId").val(obj.clerkId);
                $("#coachName").val(obj.userName);
            }else if(obj.companyId == 3){ //当登录人身份是专家时
                $("#expertId").val(obj.clerkId);
            }


        });
    });
</script>
<script type="text/html" id="barDemo">
    {{# if(hasPrivilege("detail")){ }}

    <a class="layui-btn layui-btn-primary layui-btn-xs" lay-event="detail" id="detail">查看</a>
        {{# if(d.sort == 20){ }}
            <a class='layui-badge-dot layui-bg-blue' style='left:0; right: auto; margin: 8px 0 0 53px;' id="dian4"> </a >
        {{# }else if(d.sort == 30){ }}
            <a class='layui-badge-dot layui-bg-orange' style='left:0; right: auto; margin: 8px 0 0 53px;' id="dian4"> </a >
        {{# } }}
    {{# }else{ }}
    <a class="layui-btn layui-btn-disabled layui-btn-xs" id="detail">查看</a>
    {{# } }}
    {{# if(hasPrivilege("feedback")){ }}

    <a class="layui-btn layui-btn-xs layui-btn-normal" style="margin: 0px 0 0 11px;" lay-event="feedback" id="feedback">反馈</a>
    {{# }else{ }}
    <a class="layui-btn layui-btn-disabled layui-btn-xs" style="margin: 0px 0 0 11px;" id="feedback">反馈</a>
    {{# } }}
    {{# if(hasPrivilege("audit")){ }}
    <a class="layui-btn layui-btn-danger layui-btn-xs" lay-event="audit" id="audit">审核</a>
    {{# if(d.sort == 10){ }}
        <a class='layui-badge-dot' style='left:0; right: auto; margin: 8px 0 0 156px;' id="dian"> </a >
    {{# } }}
    {{# }else{ }}
    <a class="layui-btn layui-btn-disabled layui-btn-xs" id="audit">审核</a>
    {{# } }}

    {{# if(hasPrivilege("revert") && d.remark == $("#expertId").val()){ }}

    <a class="layui-btn layui-btn-warm layui-btn-xs" style="margin: 0px 0 0 -19px;" lay-event="revert" id="revert">回复</a>
    {{# if(d.sort == 20 || d.sort == 30 ){ }}
    <a class='layui-badge-dot' style='left:0; right: auto; margin: 8px 0 0 205px;' id="dian3"> </a >
    {{# } }}

    {{# }else{ }}
    <a class="layui-btn layui-btn-disabled layui-btn-xs" style="margin: 0px 0 0 -19px;" id="revert">回复</a>
    {{# } }}
    {{# if(hasPrivilege("consult")){ }}

    <a class="layui-btn layui-btn-xs layui-btn-normal" style="margin: 0px 0 0 10px;" lay-event="consult" id="consult">申请咨询</a>
    {{# if(d.sort == 10 || d.sort == 20 || d.sort == 30 ){ }}

    <a class='layui-badge-dot' style='left:0; right: auto; margin: 8px 0 0 280px;' id="dian2"> </a >

    {{# }   }}
    {{# }else{ }}
    <a class="layui-btn layui-btn-disabled layui-btn-xs" style="margin: 0px 0 0 10px;" id="consult">申请咨询</a>
    {{# } }}
    {{# if(hasPrivilege("edit")){ }}

    <a class="layui-btn layui-btn-xs" lay-event="edit" style="margin: 0px 0 0 15px;" id="edit">修改</a>
    {{# }else{ }}
    <a class="layui-btn layui-btn-disabled layui-btn-xs" style="margin: 0px 0 0 15px;" id="edit">修改</a>
    {{# } }}
    {{# if(hasPrivilege("del")){ }}

    <a class="layui-btn layui-btn-danger layui-btn-xs" lay-event="del" id="del">删除</a>
    {{# }else{ }}
    <a class="layui-btn layui-btn-disabled layui-btn-xs" id="del">删除</a>
    {{# } }}
    <!--<a class="layui-btn layui-btn-primary layui-btn-xs" lay-event="detail">查看</a>

    <a class="layui-btn layui-btn-xs layui-btn-normal" lay-event="feedback">反馈</a>

    <a class="layui-btn layui-btn-danger layui-btn-xs" lay-event="audit">审核</a>

    <a class="layui-btn layui-btn-warm layui-btn-xs" lay-event="revert">回复</a>

    <a class="layui-btn layui-btn-xs layui-btn-normal" lay-event="consult">申请咨询</a>

    <a class="layui-btn layui-btn-xs" lay-event="edit">修改</a>-->
    <!--{{# if(d.noChange == '否') { }} {{# } else{}}-->
    <!--<a class="layui-btn layui-btn-danger layui-btn-xs" lay-event="del">删除</a>-->
    <!--{{# } }}-->

</script>


<script id="file" type="text/html">
    {{# if(d.file1 == null) { }}

    {{# } else{}}
    <a href="../..{{d.file1}}" class="layui-btn layui-btn-xs layui-btn-normal" target="_blank">下载</a>
    {{# } }}
</script>
<script id="file2" type="text/html">
    {{# if(d.file2 == null) { }}

    {{# } else{}}
    <a href="../..{{d.file2}}" class="layui-btn layui-btn-xs layui-btn-normal" target="_blank">下载</a>
    {{# } }}
</script>
<script id="file3" type="text/html">
    {{# if(d.file3 == null) { }}

    {{# } else{}}
    <a href="../..{{d.file3}}" class="layui-btn layui-btn-xs layui-btn-normal" target="_blank">下载</a>
    {{# } }}
</script>
<script id="resultFile" type="text/html">
    {{# if(d.resultFile == null){ }}
    {{# }else{}}
    <a href="../..{{d.resultFile}}" class="layui-btn layui-btn-xs layui-btn-normal" target="_blank">下载</a>
    {{# } }}
</script>
<script type="text/html" id="switchTp2">
    <input type="checkbox" name="noChange" value="{{d.roleId}}" lay-skin="switch" lay-text="是|否" lay-filter="sexDemo2" {{ d.noChange == '是' ? 'checked' : 'true' }}
</script>
<script>
    layui.config({
        version: '1568076536509' //为了更新 js 缓存，可忽略
    });

    layui.use(['laydate', 'laypage', 'layer', 'table' ], function(){
        var laydate = layui.laydate //日期
            ,laypage = layui.laypage //分页
            ,layer = layui.layer //弹层
            ,table = layui.table //表格



        //执行一个 table 实例
        var table2 = table.render({
            elem: '#demo'
            ,id:'schemeId'
            ,url: '../../AtsSchemeController/selectAll?isva=1&coachId='+$("#coachId").val()//数据接口
            ,title: '方案表'
            ,width:''
            ,page: true //开启分页
            ,toolbar: "#thead" //开启工具栏，此处显示默认图标，可以自定义模板，详见文档

            //,toolbar: true //开启工具栏，此处显示默认图标，可以自定义模板，详见文档
            //,totalRow: true //开启合计行
            ,cols: [[ //表头
                {type: 'checkbox', fixed: 'left'}
                // ,{field: 'schemeId', title: '序号', align:'center', fixed: 'left'}
                ,{field: 'schemeName', title: '方案名称', align:'center', width:100, fixed: 'left'}
                ,{field: 'year', title: '方案年度', align:'center', width:91}
                ,{field: 'month', title: '方案月份', align:'center', width:88}
                ,{field: 'schemeType', title: '方案类型', align:'center', width:117}
                ,{field: 'file1', title: '附件1地址', align:'center',templet:'#file', width:97}
                ,{field: 'file2', title: '附件2地址', align:'center',templet:'#file2', width:97}
                ,{field: 'file3', title: '附件3地址', align:'center',templet:'#file3', width:97}
                ,{field: 'coachId', title: '教练员ID', align:'center', width:87}
                ,{field: 'coachName', title: '教练员姓名', align:'center', width:103}
                ,{field: 'resultTime', title: '反馈时间', align:'center', width:165}
                ,{field: 'resultExp', title: '实施情况', align:'center', width:130 }
                ,{field: 'resultEffect', title: '实施效果', align:'center', width:130}
                ,{field: 'resultFile', title: '实施附件', align:'center', width:97,templet:'#resultFile'}
                ,{fixed: 'right', title: '操作', align:'center', fixed: 'right', width:390, toolbar: '#barDemo'}
            ]]
            /*,done: function(res, curr, count){
                //如果是异步请求数据方式，res即为你接口返回的信息。
                //如果是直接赋值的方式，res即为：{data: [], count: 99} data为当前页数据、count为数据总长度
                // console.log(res);
                //得到当前页码
                // console.log(curr);
                //得到数据总量
                // console.log(count);
               var companyName = $("#companyName").val();

                if(companyName == "运动员"){
                    $("#add").attr("hidden","hidden");
                    $("#deletes").attr("hidden","hidden");
                }else if(companyName == "教练员"){

                }else if(companyName == "专家"){

                }else if(companyName == "中心领导"){

                }

            }*/
        });

        table.on('toolbar(test)', function(obj){
            var checkStatus = table.checkStatus(obj.config.id);
            var data =checkStatus.data;
            switch(obj.event){
                case 'add':
                    layer.open({
                        type: 2,
                        title: '新增',
                        shadeClose: true,
                        shade: 0.8,
                        area: ['80%', '90%'],
                        content: 'add.html?mothed=add',//iframe的url

                        /*end:function(){
                            table2.reload();
                        }*/
                    });
                    break;
                case 'select'://搜索
                    $("#coachNames").val($("#coachName").val());
                    $("#schemeNames").val($("#schemeName").val());
                    $("#begins").val($("#begin").val());
                    $("#ends").val($("#end").val());
                    table2.reload({
                        url : '../../AtsSchemeController/selectAll?isva=1'
                        ,where : {
                            coachName:$("#coachName").val(),
                            schemeName:$("#schemeName").val(),
                            begin:$("#begin").val(),
                            end:$("#end").val()
                        }

                        ,page : {
                            curPage : 1
                        }
                    });
                    $("#coachName").val($("#coachNames").val());
                    $("#schemeName").val($("#schemeNames").val());
                    $("#begin").val($("#begins").val());
                    $("#end").val($("#ends").val());
                    laydate.render({
                        elem: '#begin'
                        ,type: 'year'
                    });

                    laydate.render({
                        elem: '#end'
                        ,type: 'year'
                    });
                    break;
                case 'empty'://清空
                    $("#coachName").val();
                    $("#schemeName").val();
                    $("#begin").val();
                    $("#end").val();
                    $("#coachNames").val();
                    $("#schemeNames").val();
                    $("#begins").val();
                    $("#ends").val();
                    table2.reload();
                    laydate.render({
                        elem: '#begin'
                        ,type: 'year'
                    });

                    laydate.render({
                        elem: '#end'
                        ,type: 'year'
                    });
                    break;
                case 'deletes'://批量删除
                    var schemeIds="";
                    $.each(data,function(indexs,item){
                        schemeIds+=item.schemeId+",";
                    });
                    if(schemeIds==""){
                        layer.msg("请选择一行！");
                    }else{
                        layer.confirm('真的删除选中的行么', function(index){
                            $.ajax({
                                url:"../../AtsSchemeController/deleteScheme",
                                type:"post", // 传输类型
                                data:{'schemeIds' : schemeIds},
                                success:function(obj){
                                    layer.msg("删除成功",{
                                        icon:1,
                                        time:1000,
                                    },function(){
                                        var indexs = parent.layer.getFrameIndex(window.name);
                                        parent.layer.close(indexs);
                                    });
                                    table2.reload();
                                    return false ;
                                },
                                error:function(e){
                                    layer.msg("删除失败",{
                                        icon:1,
                                        time:1000,
                                    },function(){
                                        var indexs = parent.layer.getFrameIndex(window.name);
                                        parent.layer.close(indexs);
                                    });
                                    table2.reload();
                                    return false ;
                                }

                            });
                        });
                    }


                    break;
                case 'oneself'://只看自己
                    table2.reload({
                        url : '../../AtsSchemeController/selectAll?isva=1'
                        ,where : {
                            coachId:$("#coachId").val(),
                            coachName:null,
                            schemeName:null,
                            begin:null,
                            end:null,
                        }
                        ,page : {
                            curPage : 1
                        }
                    });
                    break;
                case 'all'://查看全部
                    table2.reload({
                        url : '../../AtsSchemeController/selectAll?isva=1'
                        ,where : {
                            coachId:null,
                            coachName:null,
                            schemeName:null,
                            begin:null,
                            end:null,
                        }
                        ,page : {
                            curPage : 1
                        }
                    });
                    break;
                //自定义头工具栏右侧图标 - 提示
                case 'LAYTABLE_TIPS':
                    layer.alert('这是工具栏右侧自定义的一个图标按钮');
                    break;
            };
        });

        laydate.render({
            elem: '#begin'
            ,type: 'year'
        });

        laydate.render({
            elem: '#end'
            ,type: 'year'
        });


        //监听行工具事件
        table.on('tool(test)', function(obj){ //注：tool 是工具条事件名，test 是 table 原始容器的属性 lay-filter="对应的值"
            var data = obj.data //获得当前行数据
                ,layEvent = obj.event; //获得 lay-event 对应的值
            if(layEvent === 'detail'){
                layer.open({
                    type: 2,
                    title: '查看',
                    shadeClose: true,
                    shade: 0.8,
                    area: ['80%', '90%'],
                    content: 'detail.html?schemeId='+data.schemeId+'&file1='+data.file1+'&file2='+data.file2+'&file3='+data.file3+'&resultFile='+data.resultFile+'&suggest='+hasPrivilege("suggest"),//iframe的url
                    success: function (layero, index) {    //成功获得加载changefile.html时，预先加载，将值从父窗口传到 子窗口
                        let body = layer.getChildFrame('body', index);
                        body.find("#schemeId").val(data.schemeId);   //通过class名进行获取数据
                        body.find("#schemeNames").text(data.schemeName);
                        body.find("#schemeName").val(data.schemeName);
                        body.find("#schemeType").text(data.schemeType);
                        body.find("#coachName").text(data.coachName);
                        body.find("#coachNames").text(data.coachName);
                        body.find("#resultTime").text(data.resultTime);
                        body.find("#resultExp").text(data.resultExp);
                        body.find("#resultEffect").text(data.resultEffect);
                        body.find("#resultFile").attr("href","../.."+data.resultFile);
                        layui.form.render();
                    }

                });
            } else if(layEvent === 'del'){
                layer.confirm('真的删除行么', function(index){
                    obj.del(); //删除对应行（tr）的DOM结构
                    var schemeId = data.schemeId;
                    $.ajax({
                        type:"GET",
                        async:false,     //设为同步请求（异步加载的话后面的遍历方法获取不到option）
                        url:"../../AtsSchemeController/deleteScheme",//获取option值得方法返回LIST<String>类型
                        data:{'schemeId' : schemeId},
                        success:function(data){
                            if(data.num == 1){
                                layer.msg(data.msg,{
                                    icon:1,
                                    time:1000,
                                },function(){
                                    var indexs = parent.layer.getFrameIndex(window.name);
                                    parent.layer.close(indexs);
                                });
                                return false ;
                            }
                        }
                    });
                    layer.close(index);
                    //向服务端发送删除指令
                });
            } else if(layEvent === 'edit'){
                layer.open({
                    type: 2,
                    title: '修改',
                    shadeClose: true,
                    shade: 0.8,
                    area: ['80%', '90%'],
                    content: 'add.html?id='+data.month+'&mothed=update&schemeId='+data.schemeId,//iframe的url
                    success: function (layero, index) {    //成功获得加载changefile.html时，预先加载，将值从父窗口传到 子窗口
                        //// console.log(obj.data.editAble);
                        let body = layer.getChildFrame('body', index);
                        //console.log(rowselect[0].filename);
                        body.find("#schemeName").val(data.schemeName);   //通过class名进行获取数据
                        body.find("#test2").val(data.year);
                        // alert(data.month);
                        //body.find("#months").val(data.month);
                        body.find("#schemeType").val(data.schemeType);
                        body.find("#location").val(data.file1);
                        body.find("#location2").val(data.file2);
                        body.find("#location3").val(data.file3);
                        body.find("#coachId").val(data.coachId);
                        body.find("#coachName").val(data.coachName);
                        body.find("#mothed").val("update");
                        body.find("#schemeId").val(data.schemeId);

                        // body.find("#roleTime").val(layui.util.toDateString(data.roleTime, 'yyyy-MM-dd HH:mm:ss'));
                        //body.find(".filepath").val(rowselect[0].path);//意思是将rowselect[0].path这个值传递到子窗口的class="filepath"这个的文本框中，（预先加载）
                        //body.find(".menuid").val(rowselect[0].previousid);
                        // layui.form.render('select');
                        layui.form.render();
                    },
                    /*end:function(){
                        table2.reload();
                    }*/
                });
            } else if(layEvent === 'feedback'){
                layer.open({
                    type: 2,
                    title: '反馈',
                    shadeClose: true,
                    shade: 0.8,
                    area: ['80%', '90%'],
                    content: 'feedback.html?resultExp='+data.resultExp,//iframe的url
                    success: function (layero, index) {    //成功获得加载changefile.html时，预先加载，将值从父窗口传到 子窗口

                        let body = layer.getChildFrame('body', index);
                        body.find("#schemeId").val(data.schemeId);   //通过class名进行获取数据
                        body.find("#resultExp").val(data.resultExp);
                        body.find("#resultEffect").val(data.resultEffect);
                        body.find("#result").val(data.resultFile);
                        layui.form.render();
                    }/*,
                    end:function(){
                        table2.reload();
                    }*/
                });
            } else if(layEvent === 'audit'){
                layer.open({
                    type: 2,
                    title: '审核',
                    shadeClose: true,
                    shade: 0.8,
                    area: ['80%', '90%'],
                    content: 'audit.html?schemeId='+data.schemeId+'&sort='+data.sort,//iframe的url
                    success: function (layero, index) {    //成功获得加载changefile.html时，预先加载，将值从父窗口传到 子窗口
                        let body = layer.getChildFrame('body', index);
                        body.find("#schemeName").val(data.schemeName);   //通过class名进行获取数据
                        body.find("#coachName").val(data.coachName);
                        layui.form.render();
                    },
                    /*end:function(){
                        table2.reload();
                    }*/
                });
            } else if(layEvent === 'revert'){
                layer.open({
                    type: 2,
                    title: '专家回复界面',
                    shadeClose: true,
                    shade: 0.8,
                    area: ['80%', '90%'],
                    content: 'revert.html?schemeId='+data.schemeId+'&sort='+data.sort,//iframe的url
                    success: function (layero, index) {    //成功获得加载changefile.html时，预先加载，将值从父窗口传到 子窗口
                        let body = layer.getChildFrame('body', index);
                        body.find("#schemeName").val(data.schemeName);   //通过class名进行获取数据
                        body.find("#coachId").val(data.coachId);
                        body.find("#coachName").val(data.coachName);
                        body.find("#schemeId").val(data.schemeId);
                        layui.form.render();
                    },
                    /*end:function(){
                        table2.reload();
                    }*/
                });
            } else if(layEvent === 'consult'){
                layer.open({
                    type: 2,
                    title: '申请咨询专家',
                    shadeClose: true,
                    shade: 0.8,
                    area: ['80%', '90%'],
                    content: 'consult.html?schemeId='+data.schemeId+'&sort='+data.sort,//iframe的url
                    success: function (layero, index) {    //成功获得加载changefile.html时，预先加载，将值从父窗口传到 子窗口

                        let body = layer.getChildFrame('body', index);

                        body.find("#schemeName").val(data.schemeName);   //通过class名进行获取数据

                        body.find("#schemeId").val(data.schemeId);

                        layui.form.render();
                    },
                    /*end:function(){
                        table2.reload();
                    }*/
                });
            }
        });

        //将日期直接嵌套在指定容器中
        var dateIns = laydate.render({
            elem: '#laydateDemo'
            ,position: 'static'
            ,calendar: true //是否开启公历重要节日
            ,mark: { //标记重要日子
                '0-10-14': '生日'
                ,'2018-08-28': '新版'
                ,'2018-10-08': '神秘'
            }
            ,done: function(value, date, endDate){
                if(date.year == 2017 && date.month == 11 && date.date == 30){
                    dateIns.hint('一不小心就月底了呢');
                }
            }
            ,change: function(value, date, endDate){
                layer.msg(value)
            }
        });

        //分页
        laypage.render({
            elem: 'pageDemo' //分页容器的id
            ,count: 100 //总页数
            ,skin: '#1E9FFF' //自定义选中色值
            //,skip: true //开启跳页
            ,jump: function(obj, first){
                if(!first){
                    layer.msg('第'+ obj.curr +'页', {offset: 'b'});
                }
            }
        });




    });
</script>
</body>
</html>        